

import junit.framework.TestCase;

interface A {}

class B implements FinalA {
	public String printString() {
		return "B Class";
	}
}

public class TestClass extends TestCase {
	public void testAB() {
		B b1 = new B();
		assertTrue(b1 instanceof FinalA);
		assertTrue(b1 instanceof B);
		
		FinalA a = new B();
		assertTrue(a instanceof FinalA);
		assertTrue(a instanceof B);
		
		B b = (B) a;
		assertEquals("B Class", b.printString());
	}
	
	
}
